package cn.qayy.service;


import java.util.List;
import java.util.Map;

import org.springframework.web.bind.annotation.RequestParam;

import com.github.pagehelper.PageInfo;

import cn.qayy.dto.CargoInvoiceApplyDTO;
import cn.qayy.po.CargoInvoiceApply;

/**
 * @author wangyu
 * 发货、开票申请 接口
 */
public interface ICargoService extends BasicService{
	/**
	 * 分页查询
	 * @param params
	 * @return
	 */
    PageInfo<CargoInvoiceApply> selectForList(CargoInvoiceApplyDTO dto) throws Exception;
    
    /***
     * 查询数据为了下载
     * @param params
     * @return
     * @throws Exception
     */
    List<Map<String, Object>> selectForDown(CargoInvoiceApplyDTO dto) throws Exception;
    /**
     * 通过id查询
     * @param params
     * @return
     */
    CargoInvoiceApply selectByID(@RequestParam Long id) throws Exception;
    /**
     * 通过通过map参数查询最近添加的
     * @param params
     * @return
     */
    CargoInvoiceApply selectLastOneByMap(Map<String, Object> params) throws Exception;
    
    List<CargoInvoiceApply> checkRssociation(Map<String, Object> params);
    
    int deleteByPrimaryKey(long id);
}
